package com.party.admin.web.dto.output.dbAnalyze;

import com.party.core.model.dbAnalyze.DbAnalyze;
import org.springframework.beans.BeanUtils;

/**
 * Created by wei.li
 *
 * @date 2017/8/3 0003
 * @time 11:08
 */
public class DbAnalyzeOutput {

    //表名称
    private String tableName;

    //行数
    private Integer rows;

    //今天
    private Integer today;

    //本周
    private Integer week;

    //本月
    private Integer month;

    public DbAnalyzeOutput() {
        this.today = 0;
        this.week = 0;
        this.month = 0;
    }

    public String getTableName() {
        return tableName;
    }

    public void setTableName(String tableName) {
        this.tableName = tableName;
    }

    public Integer getRows() {
        return rows;
    }

    public void setRows(Integer rows) {
        this.rows = rows;
    }

    public Integer getToday() {
        return today;
    }

    public void setToday(Integer today) {
        this.today = today;
    }

    public Integer getWeek() {
        return week;
    }

    public void setWeek(Integer week) {
        this.week = week;
    }

    public Integer getMonth() {
        return month;
    }

    public void setMonth(Integer month) {
        this.month = month;
    }

    public static DbAnalyzeOutput transform(DbAnalyze dbAnalyze){
        DbAnalyzeOutput dbAnalyzeOutput = new DbAnalyzeOutput();
        BeanUtils.copyProperties(dbAnalyze, dbAnalyzeOutput);
        return dbAnalyzeOutput;
    }
}
